function userlogin() {
		var url = "/OA/user/user_login.do";
		var username = $("#username").val();
		var password = $("#password").val();
		$.ajax({
			url : url,
			dataType : 'html',
			data : ({'username':username,
				'password':password
			}),
			success : function(data) {
				if(data==0){
					location.href = "/OA/pagejump/index"
				}else{
					$("#loginReturn").html("<font color='red'>用户名或者密码错误</font>")
				}
				
			}
		})
	}

function select_type(){
	var vs = $('select  option:selected').val();
	if(vs == "time"){
		$("#select_text").html("<div id='inputDiv'><input type='date' id='select_input' name='select_input'></div>");
	}else if(vs == "product_name"){
		$("#select_text").html("<div id='inputDiv'>产品名称:<input type='text' id='select_name' name='select_name' autocomplete='off'></div><div>型号:<input type='text' id='select_model' name='select_model' autocomplete='off'></div>");
	}else if(vs == "client_name"){
		$("#select_text").html("<div id='inputDiv'>客户名称:<input type='text' id='select_input' name='select_input' autocomplete='off'></div>");
	}else if(vs == "client_phone"){
		$("#select_text").html("<div id='inputDiv'>客户手机号:<input type='text' id='select_input' name='select_input' autocomplete='off'></div>");
	}else if(vs == "uptown_name"){
		$("#select_text").html("<div id='inputDiv'>小区名:<input type='text' id='select_input' name='select_input' autocomplete='off'></div>");
	}else if(vs == "service_man"){
		$("#select_text").html("<div id='inputDiv'>服务人员名称:<input type='text' id='select_input' name='select_input' autocomplete='off'></div>");
	}
}

function selectUseList(){
	var vs = $('select  option:selected').val();
	if(vs == "product_name"){
		$("#inputDiv").children('font').remove();
		$("#inputDiv").append("<font color='red'>不能为空</font>");
		if($("#select_name").val()==""){
			$("#select_name").focus();
		}else{
			$("#select_model").focus();
		}
	}else{
		$("#inputDiv").children('font').remove();
		$("#inputDiv").append("<font color='red'>不能为空</font>");
		$("#select_input").focus();
	}
	$("#selectUseForm").submit();
}
